// JavaScript Document
$(function () {
	initDetail();
});
//初始化
function initDetail(){
	getInfo(getQueryString("id"));
}
//获取详情
function getInfo(id){
	var str = 'crrorUuid='+encodeURIComponent(id);
	getOData(str,"coreRepairOrder/views",{fn:function(oData){
		if(oData.code == 1) {
			var crrorStatus = oData.data.crrorStatus;//:1支付中2支付成功3支付失败4已联系5交易成功
			var crrorStatusCH="支付成功";
			if(2==crrorStatus){
				crrorStatusCH="支付成功";
			}else if(3==crrorStatus){
				crrorStatusCH="支付失败";
			}else if(4==crrorStatus){
				crrorStatusCH="已联系";
			}else if(5==crrorStatus){
				crrorStatusCH="交易成功";
			}
			$(".crrorUser").text(oData.data.crusrName || "");
			$(".crrorTel").text(oData.data.crrorTel || "");
			$(".crrorCdate").text(oData.data.crrorCdate || "");
			$(".crrorUdate").text(oData.data.crrorUdate || "");
			$(".crrorStatus").text(crrorStatusCH);
			$(".crrorTotal").text(oData.data.crrorTotal);
			$(".crrorSjFee").text(oData.data.crrorSjFee);
			$(".crrorSyScore").text(oData.data.crrorSyScore);
			$(".crrorDkFee").text(oData.data.crrorDkFee);
			$(".crrorRemarks").text(oData.data.crrorRemarks || "");
			$(".crrorGoods").text(oData.data.crrorGoods || "");
		} else {
			alert(data.errMsg);
		}
	}});
}
